
import requests

form_params = {
    'key': "gender",
    'value': 1,
}
url = "https://edith.xiaohongshu.com/api/sns/v2/user/info"

x = {
    'xy-common-params': 'deviceId=8e2396c3-4f11-40a2-8c48-f8d3b88e4a42&device_fingerprint=20210714135832eeee4ecc554817483a932b25dbc8068f0156e0caa323fd6c&device_fingerprint1=20210714135832eeee4ecc554817483a932b25dbc8068f0156e0caa323fd6c&sid=session.1626242314244602711498&t=1626242311&fid=1626242311104ec86dbc7312a52dd218460b1a275290&platform=android&lang=zh-Hans&channel=YingYongBao&build=6930175&versionName=6.93.0&project_id=ECFAAF&app_id=ECFAAF01&tz=Asia%2FShanghai&uis=light&identifier_flag=2',
    'User-Agent': 'Dalvik/2.1.0 (Linux; U; Android 5.1.1; 2014813 MIUI/7.11.16) Resolution/720*1280 Version/6.93.0 Build/6930175 Device/(Xiaomi;2014813) discover/6.93.0 NetType/WiFi',
    'shield': 'XYAAAAAQAAAAEAAABTAAAAUzUWEe0xG1IbD9/c+qCLOlKGmTtFa+lG435bfuJfQv5LwoDmmLRlTJ2s+eZbz8Miict+g/Q6RgwfR2ePN+3y2Xk1hOc/QwU+NI2qX4g+n4aoHrY7',
    'xy-platform-info': 'platform=android&build=6930175&deviceId=8e2396c3-4f11-40a2-8c48-f8d3b88e4a42'
}



"""

&device_fingerprint=20210714135832eeee4ecc554817483a932b25dbc8068f0156e0caa323fd6c
&device_fingerprint1=20210714135832eeee4ecc554817483a932b25dbc8068f0156e0caa323fd6c
&sid=session.1626242314244602711498&t=1626242311




&build=6930175




&launch_id=1626238232





"""

headers = {
    "xy-common-params": "deviceId=76688507-c3db-3585-a282-70c7116d1c71&identifier_flag=2&tz=Asia%2FShanghai&fid=16262382321027cd9dc0691dbdf3a3e7adbd040ce014&app_id=ECFAAF01&device_fingerprint1=202107101522494b5a757e17110e860d6de86e2c15822f01b42f06e8730b88&uis=light&launch_id=1626238232&project_id=ECFAAF&device_fingerprint=2021071412503295cf4648dae24f4b5b841aabd88eb0a600709487f56f2916&versionName=6.90.0.1&platform=android&sid=session.1626238264057510570293&t=1626238573&build=6900179&x_trace_page_current=new_user_profile_page&lang=zh-Hans&channel=PMgdt19935739",
    "User-Agent": "Dalvik/2.1.0 (Linux; U; Android 5.1.1; Mi 10 Build/LMY49I) Resolution/1080*1920 Version/6.90.0.1 Build/6900179 Device/(Xiaomi;Mi 10) discover/6.90.0.1 NetType/WiFi",
    "shield": "XYAAAAAQAAAAEAAABTAAAAUzUWEe0xG1IbD9/c+qCLOlKGmTtFa+lG43AHfOFXQ6RFw4K4lrNnS52r/LQNz8Mv1Mh+gKA6EgxJETaPZbryiCozgeU3EkhaUvafFTd5Zr+kCqb3",
    "xy-platform-info": "platform=android&build=6900179&deviceId=76688507-c3db-3585-a282-70c7116d1c71"
}

resp = requests.post(url, data=form_params, headers=headers)
print(resp.text)